package com.zjh.reactive;

import reactor.core.publisher.Flux;

import java.util.Arrays;

/**
 * @Auther: zjh
 * @Date: 2025/11/3 - 11 - 03 - 16:55
 * @Description: com.zjh.reactive
 * @version: 1.0
 */
public class FlatMapDemo {
    public static void main(String[] args) {
        Flux.just(Arrays.asList(1,2,3),Arrays.asList(4,5,6))
                .flatMap(e->Flux.just(e)
                        .doOnNext(el-> System.out.println(el))
                ).subscribe(System.out::println);
    }
}
